<?php
/**
* Class teia\webdev\php\core\Constants
* Constants
*
* @author Bernardo Quibiana
* @date created: 20111003
*
* @date modified: 20111028
* @modified: Bernardo Quibiana
*/

// namespace declaration: Constants
namespace teia\webdev\php\core;

/*
 * Password validation
 */

define('MIN_PWD_LENGTH', 6);
define('MAX_PWD_LENGTH', 16);
define('PWD_REGEX', "#.*^(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9]).*$#");
//define('PWD_REGEX', "#.*^(?=.{MIN_PWD_LENGTH,MAX_PWD_LENGTH})(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9]).*$#"); // include length constraint;

/*
 * Recaptcha
 */

define('RECAPTCHA_PUB_KEY', '6LcU2MkSAAAAAHerC1vOmYieUbJzDQ0ZkLVcwm7o');
define('RECAPTCHA_PRIV_KEY', '6LcU2MkSAAAAAIoquQk7393VEplQb8QPBLLgd0f6');

/*
 * Navigation
 */
define('FORCE_HTTPS', TRUE);

/*
* URLs
*/

define('ON_SIGNUP_URL', '/');
define('ON_LOGIN_URL', '/');
define('ON_LOGOUT_URL', '/');

define('PWD_HELP_URL', 'passwordhelp.php');

/*
* Date validation
*/

define('DEFAULT_TIME_ZONE', 'Africa/Luanda');

/*
* Image size
 */

define('SLIDE_WIDTH', 620);
define('SLIDE_HEIGHT', 320);

define('THUMBNAIL_WIDTH', 135);
define('THUMBNAIL_HEIGHT', 135);

/*
 * Texts
 */

define('PWD_TOO_SHORT_ERR_TXT', 'Password is too short! Should have between ' . MIN_PWD_LENGTH . ' and ' . MAX_PWD_LENGTH . ' characters.');
define('PWD_TOO_LONG_ERR_TXT', 'Password is too long! Should have between ' . MIN_PWD_LENGTH . ' and ' . MAX_PWD_LENGTH . ' characters.');
define('PWD_PAT_MISMATCH_ERR_TXT', 'Invalid password composition! Should contain at least: 1 lower case letter, 1 upper case letter, 1 digit.');
define('PWD_REP_MISMATCH_ERR_TXT', 'Invalid passwords! The two passwords do not match.');

define('ON_LOGOUT_TXT', 'Log-out successful.');
define('INVALID_DATETIME_ERR_TXT', 'Invalid date-time value!');

define('AGREEMENT_TXT', 'By checking this box, I confirm that I have read and agree to be bound by the Terms & Privacy. I also confirm that I am of the legal age of majority in the jurisdiction in which I reside (at least 18 years of age in many countries).');

?>